export type JSONValue = boolean | string | number | null | undefined | JSONArray | JSONObject;
export type JSONArray = JSONValue[];
export interface JSONObject {
  [key: string]: JSONValue;
}
export interface JSExpression {
  type: 'JSExpression';
  /**
   * 表达式字符串
   */
  value: string;
}

export interface JSFunction {
  type: 'JSFunction';
  /**
   * 函数定义，或直接函数表达式
   */
  value: string;
}
export type CompositeValue = JSONValue | JSExpression | JSFunction | CompositeArray | CompositeObject;
export type CompositeArray = CompositeValue[];
export interface CompositeObject {
  [key: string]: CompositeValue;
}
